In [1]:
# Standard setup block for running Python code
from __future__ import division, print_function
import os
if os.path.split(os.getcwd())[-1] == "Lab notebooks":
os.chdir("../../")
print("Moved to experiment root directory")
from Modules.processing import *
from Modules.plotting import *
plt.style.use("Config/plotstyle.mplstyle")
%matplotlib inline
Started at 11:30 AM.
Torqued upper curved jaw servo coupling. Wiped corrosion from turbine mounting frame.
Homed turbine axis.
12:06 PM -- Filled tank about 2 mm to reach 2.44 m depth. Starting strut torque runs with covers.
12:14 PM -- Rotated turbine at 20, 40, 60 RPM to see how things look. At 60 RPM, there is a noticeable flow at the surface, but torque looks fairly constant--about 35 Nm.
12:17 PM -- Homed y- and z-axes.
12:21 PM -- Starting Strut-torque-covers
.
12:49 PM -- Finished Strut-torque-covers
. Peak torque was about 80 Nm.
1:10 PM -- Did dummy tow with strut covers and no blades. Torque was around -30 Nm max.
1:24 PM -- Mixed up tank and did another 2 dummy tows.
1:35 PM -- Added a cup of seeding to the tank since we are doing wake measurements for the runs with no blades.
1:37 PM -- Starting Perf-1.0-no-blades-covers
.
Looks like we add about 10 Nm of parasitic torque when towing.
4:05 PM -- Finished Perf-1.0-no-blades-covers
. Backing up data.
4:59 PM -- Reinstalled turbine with no blades or strut covers.
5:25 PM -- Re-homed all axes. Starting Perf-1.0-no-blades
.
7:53 PM -- Completed Perf-1.0-no-blades
. Backing up data.
In [15]:
process_strut_torque(23, plot=True, verbose=True, covers=True)
Out[15]:
In [12]:
tsr_ref = []
cp_loss = []
for n in range(26):
tsr, cp = process_strut_torque(n, covers=True)
tsr_ref.append(tsr)
cp_loss.append(cp)
plt.plot(tsr_ref, cp_loss, "-o")
plt.xlabel("$\lambda$")
plt.ylabel("$C_P$ loss estimate")
plt.show()
In [59]:
# Calculating tare torque test matrix for experiment
def calc_rpm((tow_speed, tsr)):
omega = tsr*tow_speed/R
return omega/(2*np.pi)*60.0
save = False
lowest = (0.2, 1.0) # tow_speed, tsr
highest = (1.4, 4.0)
rpm_start = calc_rpm(lowest)
rpm_end = calc_rpm(highest)
steps = 25
rpms = np.linspace(rpm_start, rpm_end, steps)
revs = np.ones(len(rpms))*30.0
revs[0] = 4
revs[1] = 8
revs[2] = 12
revs[3] = 16
revs[4] = 20
revs[5] = 24
revs[-1] = 32
df = pd.DataFrame()
df["rpm"] = rpms
df.index.name = "run"
df["revs"] = revs
if save:
df.to_csv("Config/Test plan/Tare-torque.csv")
df["minutes"] = revs/rpms
df["samples"] = np.floor(df.minutes*60*2000)
df["samples_per_rev"] = df.samples/df.revs
print("Total time (minutes):", df.minutes.sum())
df
Out[59]: